/* License Page Styles */

/* Status Notice with button */
.seopress-license-status-notice {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	flex-wrap: wrap;
}

.seopress-license-status-notice p {
	flex: 1;
	margin: 0;
}

.seopress-license-status-notice .btn {
	flex-shrink: 0;
}

/* Two Column Layout */
.seopress-license-layout {
	display: grid;
	grid-template-columns: 1fr 380px;
	gap: 32px;
}

/* Main Card */
.seopress-license-card {
	background: white;
	padding: 32px;
	border-radius: 8px;
	border: 1px solid var(--borderColor, #dcdcde);
}

.seopress-license-card h3 {
	margin: 0 0 24px 0;
	font-size: var(--titleFontSize, 18px);
	font-weight: 600;
	color: var(--titleColor, #1d2327);
}

/* Error Notice */
.seopress-license-error {
	margin-bottom: 24px;
	padding: 12px 16px;
	background-color: #fcf0f1;
	border-left: 4px solid var(--colorAlert, #d63638);
	border-radius: 4px;
}

.seopress-license-error p {
	margin: 0;
	color: var(--colorAlert, #d63638);
}

.seopress-license-error .dashicons {
	vertical-align: middle;
}

/* License Key Field */
.seopress-license-field {
	margin-bottom: 24px;
}

.seopress-license-field label {
	display: block;
	margin-bottom: 8px;
	font-size: var(--fontSize, 14px);
	font-weight: 600;
	color: var(--titleColor, #1d2327);
}

.seopress-license-field input[type="text"] {
	width: 100%;
	font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
	font-size: var(--fontSize, 14px);
	padding: 12px 16px;
	border: 1px solid var(--borderColor, #dcdcde);
	border-radius: 4px;
	background: white;
}

.seopress-license-field .description {
	margin-top: 8px;
	font-size: var(--fontSize, 13px);
	color: var(--paragraphColor, #646970);
}

.seopress-license-field .info-notice {
	margin-top: 12px;
	padding: 12px 16px;
	background-color: #e7f5fe;
	border-left: 4px solid #2271b1;
	border-radius: 4px;
}

.seopress-license-field .info-notice p {
	margin: 0;
	font-size: var(--fontSize, 13px);
	color: var(--titleColor, #1d2327);
}

.seopress-license-field .info-notice .dashicons {
	color: #2271b1;
	vertical-align: middle;
	font-size: 16px;
}

/* License Actions */
.seopress-license-actions {
	padding-top: 24px;
	border-top: 1px solid var(--borderColorLight, #f0f0f1);
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	align-items: center;
}

.seopress-license-actions .spinner {
	visibility: hidden;
	float: none;
	margin: 0;
}

/* Fix spacing when hidden inputs appear before actions */
.seopress-license-card input[type="hidden"] {
	display: block;
	margin: 0;
	padding: 0;
	height: 0;
}

.seopress-license-card input[type="hidden"] + .seopress-license-actions {
	margin-top: 24px;
}

.seopress-license-actions .btn {
	padding: 12px 24px;
	border-radius: 4px;
	cursor: pointer;
}

.seopress-license-actions .btnTertiary {
	border: 1px solid var(--borderColor, #dcdcde);
	background: white;
}

.seopress-license-actions .btnPrimary {
	background: var(--backgroundPrimary);
	border: 1px solid var(--backgroundPrimary);
	color: white;
	font-weight: 600;
}

.seopress-license-actions .btnPrimary:hover:not(:disabled) {
	background: var(--backgroundPrimaryHover);
	border-color: var(--backgroundPrimaryHover);
}

.seopress-license-actions .btnPrimary:disabled {
	background: var(--backgroundPrimaryHover);
	opacity: 0.6;
	cursor: not-allowed;
}

.seopress-license-actions .btnSecondary {
	background: var(--colorAlert, #d63638);
	border: 1px solid var(--colorAlert, #d63638);
	color: white;
}

/* Status Messages */
.seopress-license-message {
	margin-top: 24px;
	padding: 16px 20px;
	border-left: 4px solid;
}

.seopress-license-message.is-error {
	background-color: #fcf0f1;
	border-color: var(--colorAlert, #d63638);
}

.seopress-license-message.is-success {
	background-color: #edfaef;
	border-color: var(--colorSuccess, #00a32a);
}

.seopress-license-message p {
	margin: 0;
	font-weight: 600;
}

.seopress-license-message.is-error p:first-child {
	color: var(--colorAlert, #d63638);
	margin-bottom: 12px;
}

.seopress-license-message.is-success p {
	color: var(--colorSuccess, #00a32a);
}

.seopress-license-message p.description {
	font-size: var(--fontSize, 13px);
	color: var(--paragraphColor, #50575e);
	margin-bottom: 8px;
	font-weight: 400;
}

.seopress-license-message .dashicons {
	vertical-align: middle;
}

/* Sidebar */
.seopress-license-sidebar {
	display: flex;
	flex-direction: column;
	gap: 20px;
}

.seopress-license-sidebar-card {
	background: white;
	padding: 24px;
	border-radius: 8px;
	border: 1px solid var(--borderColor, #dcdcde);
}

.seopress-license-sidebar-card h4 {
	margin: 0 0 16px 0;
	font-size: 15px;
	font-weight: 600;
	color: var(--titleColor, #1d2327);
	display: flex;
	align-items: center;
	gap: 8px;
}

.seopress-license-sidebar-card h4 .dashicons {
	color: var(--primaryColor);
}

.seopress-license-sidebar-card ol {
	margin: 0;
	padding-left: 20px;
	line-height: 1.8;
	font-size: var(--fontSize, 13px);
	color: var(--paragraphColor, #50575e);
}

.seopress-license-sidebar-card p {
	margin: 0 0 12px 0;
	font-size: var(--fontSize, 13px);
	color: var(--paragraphColor, #50575e);
	line-height: 1.6;
}

.seopress-license-sidebar-card code {
	padding: 2px 6px;
	background-color: #f6f7f7;
	border-radius: 3px;
	font-size: 12px;
}

.seopress-license-code-block {
	position: relative;
	margin: 12px 0;
}

.seopress-license-sidebar-card pre {
	margin: 0;
	padding: 40px 12px 12px 12px;
	background-color: #f6f7f7;
	border: 1px solid var(--borderColor, #dcdcde);
	border-radius: 4px;
	overflow-x: auto;
	word-wrap: break-word;
	white-space: pre-wrap;
	padding-right: 92px !important;
}

.seopress-license-sidebar-card pre code {
	padding: 0;
	background: none;
	font-family: 'SFMono-Regular', Consolas, 'Liberation Mono', Menlo, monospace;
	font-size: 12px;
	line-height: 1.6;
	color: var(--titleColor, #1d2327);
}

.seopress-license-copy-btn {
	position: absolute;
	top: 8px;
	right: 8px;
	display: flex;
	align-items: center;
	gap: 4px;
	padding: 6px 10px;
	background: white;
	border: 1px solid var(--borderColor, #dcdcde);
	border-radius: 3px;
	cursor: pointer;
	font-size: 12px;
	color: var(--titleColor, #1d2327);
	transition: all 0.2s;
}

.seopress-license-copy-btn:hover {
	background: var(--backgroundSecondaryHover, #f6f7f7);
	border-color: var(--primaryColor);
}

.seopress-license-copy-btn .dashicons {
	font-size: 16px;
	width: 16px;
	height: 16px;
}

.seopress-license-copy-btn.copied {
	background: var(--primaryColor);
	border-color: var(--primaryColor);
	color: white;
}

.seopress-license-sidebar-card a {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	color: var(--primaryColor);
	text-decoration: none;
	font-size: var(--fontSize, 13px);
	font-weight: 500;
}

.seopress-license-sidebar-card a .dashicons {
	font-size: 18px;
}

.seopress-license-sidebar-card ul {
	margin: 0;
	padding-left: 20px;
	line-height: 1.8;
	font-size: var(--fontSize, 13px);
	color: var(--paragraphColor, #50575e);
}

.seopress-license-sidebar-card ul li {
	margin-bottom: 8px;
}

.seopress-license-sidebar-card ul a {
	color: var(--primaryColor);
	text-decoration: none;
}

.seopress-license-sidebar-card ul a:hover {
	text-decoration: underline;
}

/* Responsive Design */
@media screen and (max-width: 1200px) {
	.seopress-license-layout {
		grid-template-columns: 1fr 320px;
		gap: 24px;
	}
}

@media screen and (max-width: 960px) {
	.seopress-license-layout {
		grid-template-columns: 1fr;
		gap: 24px;
	}

	.seopress-license-sidebar {
		flex-direction: row;
		flex-wrap: wrap;
	}

	.seopress-license-sidebar-card {
		flex: 1;
		min-width: 280px;
	}
}

@media screen and (max-width: 782px) {
	.seopress-license-status-banner {
		flex-direction: column;
		align-items: flex-start;
		gap: 12px;
	}

	.seopress-license-card {
		padding: 20px;
	}

	.seopress-license-actions {
		flex-direction: column;
	}

	.seopress-license-actions .btn {
		width: 100%;
	}

	.seopress-license-sidebar {
		flex-direction: column;
	}
}

/* External link icons */
.seopress-license-sidebar-card ul a .dashicons-external {
	font-size: 14px;
	width: 14px;
	height: 14px;
	vertical-align: middle;
	margin-left: 4px;
	opacity: 0.7;
}

.seopress-license-sidebar-card a:hover .dashicons-external {
	opacity: 1;
}

/* White Label Mode - Hide help links and SEOPress mentions */
body.seopress-white-label .seopress-help,
body.seopress-white-label .seopress-license-sidebar-card a[href*="seopress.org"] {
	display: none !important;
}

/* Remove button animations/transitions */
.seopress-license-actions .btn {
	transition: none !important;
}

.seopress-license-copy-btn {
	transition: none !important;
}
